package shared;

/**
 * BudgetBuoy
 * 
 * Simplify your personal expense management
 * 
 * @team cs2103jan13-w15-3j
 */

//--------------------------------------------------------------

/**
 * CatSpend Class
 * 
 * Description: Getters and Setters of Category Spent 
 * 
 * 
 * @package shared
 * @author Li Yin (A0085686L)
 * @editor(s) -
 */


public class CatSpend{
	private Category cat;
	private int expense;
	
	//constructor
	public CatSpend(Category _cat, int _expense){
		cat=_cat;
		expense=_expense;
	}
	
	//setters
	public Category getCat() {
		return cat;
	}
	public void setCat(Category cat) {
		this.cat = cat;
	}
	
	//mutators
	public int getExpense() {
		return expense;
	}
	public void setExpense(int expense) {
		this.expense = expense;
	}
	
	//toString
	@Override
	public String toString(){
		
		String catSpendString = cat.getName() +"                    ";
		
		return catSpendString.substring(0,20); //limited to 20 characters
	
	}
}
